//
//  MovieTableViewCell.m
//  UITalbeview周六作业
//
//  Created by dllo on 15/12/26.
//  Copyright © 2015年 lanou3g. All rights reserved.
//

#import "MovieTableViewCell.h"

@implementation MovieTableViewCell

- (void)dealloc{
    [_imageBack release];
    [_image release];
    [_lable release];
    [super dealloc];
}

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self create];
    }
    return self;
}

- (void)create{
    
    self.imageBack = [[UIImageView alloc] init];
    [self.contentView addSubview:_imageBack];
    [_imageBack release];
    
    self.image = [[UIImageView alloc] init];
    [_imageBack addSubview:_image];
    [_image release];
    
    self.lable = [[UILabel alloc] init];
    [_imageBack addSubview:_lable];
    [_lable release];
    
}

- (void)layoutSubviews{
    
    [super layoutSubviews];
    
    _imageBack.frame = CGRectMake(5, 5, 365, 150);
    _imageBack.backgroundColor = [UIColor clearColor];
    
    _image.frame = CGRectMake(10, 5, 100, 140);
    _image.backgroundColor = [UIColor clearColor];
    
    _lable.frame = CGRectMake(140, _imageBack.center.y - 25, 200, 50);
    _lable.backgroundColor = [UIColor clearColor];
    _lable.font = [UIFont systemFontOfSize:25];
    
    
}


- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
